package cn.jiyun.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

/**
 * 控制层
 */
@RestController
@RequestMapping("/demo")
public class DemoController {

    /**
     * 入门demo方法
     */
    @GetMapping("/hello")
    public Map<String,Object> hello(){
        Map<String,Object> map = new HashMap<>();
        map.put("username","张三");
        map.put("age",18);
        map.put("gender","男");
        return map;
    }
}
